home *** CD-ROM | disk | FTP | other *** search
Text File | 1997-04-25 | 4.0 KB | 147 lines | [TEXT/CWIE] |
- // ==================================================
- // ErrorMessage.r
- // Copyright (C) 1996-1997 Mizutori Tetsuya
- // July 4 ,1996; February 3, 1997.
- // ==================================================
- // All documents are pretty-printed in 10-point Geneva font.
-
- #define SystemSevenOrLater TRUE
-
- #include <Types.r>
- //#include <SysTypes.r>
- //#include <PowerPlant.r>
-
- // This file can be directly included and compiled by ReZ of CW11 or later.
- // Due to a restriction of CW11, this private version of <Errors.h> file is still needed.
- // The file includes some BAD numbers as enum value and "extern" statements, so that
- // the ReZ compiler can not pass them.
- // This private version of <Errors.h> is just copied from the original file, but
- // one extern statement "SysError()" and enum values "badComponent*" are deleted.
- // #include <Errors.h>
-
- #include "Errors.r"
-
-
- // --------------------------------------------------
- // • Pascal-Style Error Message String Resources
- // --------------------------------------------------
- #define kErrorMessage_ResType 'ErrM'
- #define kErrorMessagex_ResType 'Err#'
-
- //*---- ErrM • Pascal-Style String -----*/
- type kErrorMessage_ResType {
- pstring; /* String */
- };
-
- //*---- Err# • Pascal-Style String List -----*/
- type kErrorMessagex_ResType {
- integer = $$Countof(StringArray);
- array StringArray {
- pstring; /* String */
- };
- };
-
- // --------------------------------------------------
- // • File System
- // --------------------------------------------------
- #define kErrorMessage_FileSystem "File"
- #define kErrorMessage_AppleGuide "Apple Guide"
-
- resource kErrorMessage_ResType (
- ioErr, kErrorMessage_FileSystem, purgeable)
- { "I/O error" };
-
- resource kErrorMessage_ResType (
- bdNamErr, kErrorMessage_FileSystem, purgeable)
- { "Bad filename" };
-
- resource kErrorMessage_ResType (
- fnfErr, kErrorMessage_FileSystem, purgeable)
- { "File not found" };
-
- resource kErrorMessage_ResType (
- dirNFErr, kErrorMessage_FileSystem, purgeable)
- { "Directory not found" };
-
- resource kErrorMessage_ResType (
- opWrErr, kErrorMessage_FileSystem, purgeable)
- { "File already open for writing" };
-
- resource kErrorMessage_ResType (
- permErr, kErrorMessage_FileSystem, purgeable)
- { "Attempt to open locked file for writing" };
-
- resource kErrorMessage_ResType (
- wrPermErr, kErrorMessage_FileSystem, purgeable)
- { "Write permittions does not allow writing" };
-
- resource kErrorMessage_ResType (
- fLckdErr, kErrorMessage_FileSystem, purgeable)
- { "File is locked" };
-
- resource kErrorMessage_ResType (
- vLckdErr, kErrorMessage_FileSystem, purgeable)
- { "Volume is locked or read-only" };
-
- resource kErrorMessage_ResType (
- wPrErr, kErrorMessage_FileSystem, purgeable)
- { "Diskette is write-protected" };
-
- resource kErrorMessage_ResType (
- kAGErrAppleGuideNotAvailable, kErrorMessage_AppleGuide, purgeable)
- { "Can't open guide file. Please install Apple Guide extension file in your system." };
-
- resource kErrorMessage_ResType (
- kAGErrDatabaseOpen, kErrorMessage_AppleGuide, purgeable)
- { "Apple Guide file is already open" };
-
- resource kErrorMessage_ResType (
- kAGErrDatabaseNotAvailable, kErrorMessage_AppleGuide, purgeable)
- { "Apple Guide file was not found. Please locate guide file at the same folder of application." };
-
-
- // --------------------------------------------------
- // • Error Box
- // --------------------------------------------------
- #define ALRT_ErrorBox 9000
- #define ALRT_ErrorBoxTitle "Error Box"
-
- resource 'DITL' (ALRT_ErrorBox, ALRT_ErrorBoxTitle, purgeable) {
- {
- {152, 143, 172, 201},
- Button { enabled, "OK" },
-
- {1152, 264, 1172, 322},
- Button { enabled, "Cancel" },
-
- // {12, 20, 44, 52},
- // Icon { disabled, 1 },
-
- {12, 72, 44, 272},
- StaticText { disabled, "Error Diagnosis" },
-
- {52, 72, 148, 328},
- StaticText { disabled,
- "Category: ^0\n"
- "Code: ^1\n"
- "Status: ^2\n"
- "^3"
- }
- }
- };
-
-
- resource 'ALRT' (ALRT_ErrorBox, ALRT_ErrorBoxTitle, purgeable) {
- {51, 95, 231, 439},
- ALRT_ErrorBox,
- {
- OK, visible, silent,
- OK, visible, silent,
- OK, visible, silent,
- OK, visible, silent
- },
- alertPositionMainScreen
- };
-
- // end of resources
-